package com.quanyan.ic.vendingMachine.http.service;

import com.quanyan.ic.common.paging.PageResult;
import com.quanyan.ic.vendingMachine.http.request.ReqRsptRecordCondition;
import com.quanyan.ic.vendingMachine.http.request.ReqSalesRecordCondition;
import com.quanyan.ic.vendingMachine.model.*;

import java.util.List;

/**
 * Created by zhuo.shi on 2017/7/26.
 */
public interface VmAdminService {

    List<VmCategory> vmCategoryList();

    String createPlaceVm(VmPlaceMapping mapping);

    void updatePlaceVm(VmPlaceMappingExt ext);

    VmPlaceMapping findPlaceVm(String vmNumber);

    boolean validatePlaceVm(String vmNumber);

    PageResult<List<VmPlaceMapping>> queryPlaceVmMappingList(
            Integer cityId, Integer placeId, Integer pageNo, Integer pageSize);

    void deletePlaceVmMapping(Integer id);

    void disablePlaceVmMapping(Integer id);

    List<VendingMachine> queryPlaceVmInfoList(
            Integer placeId, boolean isShowInventory, boolean isCheckInventory);

    void createGridGoodsMapping(String vmNumber, List<String> gridList, GoodsInfo goodsInfo);

    void clearGridGoodsMapping(String vmNumber, List<String> gridList);

    InventoryWarningConfig getInventoryWarningConfig(Integer placeId);

    void setInventoryWarningConfig(InventoryWarningConfig config);

    PageResult<List<ReplenishmentRecord>> queryRsptRecordList(ReqRsptRecordCondition condition);

    PageResult<List<SalesRecord>> querySalesRecordList(ReqSalesRecordCondition condition);

    void goodsReplenishment(String vmNumber, List<ReplenishmentInfo> rsptInfoList, VmUserPwd userPwd);

    VendingMachine findVendingMachine(String vmNumber, boolean showInventory, boolean checkInventory);

    String findVmCustomerTel(Integer placeId);

    String findVmCustomerTel(String vmNumber);

    List<VmPoster> findVmPoster(Integer placeId);

    void deleteVmPoster(Integer id);

    void deleteUserPwd(Integer id);

    List<VmUserPwd> findVmUserPwd(Integer placeId);
}
